import request from '@/utils/request'
import { getEldersByName, getAllEldersByName } from '@/api/nursing/elderBasic/index.ts'

// 查询老人列表
export function listElder(query) {
  return request({
    url: '/nursing/elderBasic/list',
    method: 'get',
    params: query
  })
}

// 根据老人姓名查询
export function getEldersList(query) {
  return getEldersByName(query.elderName);
}

// 查询老人详细
export function getElder(elderId) {
  return request({
    url: '/nursing/elderBasic/' + elderId,
    method: 'get'
  })
}

// 导出方便调用的方法
export default {
  listElder,
  getEldersList,
  getElder
} 